<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<ui:composition xmlns:ui="http://java.sun.com/jsf/facelets"
                template="/resources/template/template.xhtml"
                xmlns:h="http://java.sun.com/jsf/html"
                xmlns="http://www.w3.org/1999/xhtml"
                xmlns:p="http://primefaces.org/ui">


    <ui:define name="content">

        <h:panelGroup >
            <h:form  >
                <h:panelGrid columns="2">
                    <h:outputLabel styleClass="noPrintButton" value="User Name"/>
                    <p:autoComplete converter="webUs" completeMethod="#{webUserController.completeUser}"
                                     styleClass="noPrintButton"
                                    forceSelection="true"
                                    var="w" itemLabel="#{w.webUserPerson.name}" itemValue="#{w}"
                                    value="#{sessionController.webUser}" ></p:autoComplete>
                    <h:outputLabel value="Current Drawer"/>
                    <p:autoComplete value="#{sessionController.webUser.drawer}"
                                    forceSelection="true" converter="drawerCon"
                                    completeMethod="#{drawerController.completeDrawer}" var="s"
                                    itemLabel="#{s.name}" itemValue="#{s}" ></p:autoComplete>

                    <p:commandButton ajax="false" value="Update" action="#{sessionController.updateOtherUser}" onclick="onSubmitButton();"/>
                </h:panelGrid>
            </h:form>

        </h:panelGroup>

    </ui:define>

</ui:composition>
